package com.fyyg.common.result;

import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;

/**
 * 返回结果
 */
public class LayuiResultInfo {

    private int code;
    private String msg;
    private int count;
    private Object data;
    
    
	
	/**
     * 将对象转为json格式
     * @return
     */
    public JSON ConversionJSON(LayuiResultInfo res) {
    	JSONObject json = new JSONObject();
    	json.put("code", res.getCode());
    	json.put("msg", res.getMsg());
    	json.put("count", res.getCount());
    	json.put("data", res.getData());
    	return json;
    }



	public int getCode() {
		return code;
	}



	public void setCode(int code) {
		this.code = code;
	}



	public String getMsg() {
		return msg;
	}



	public void setMsg(String msg) {
		this.msg = msg;
	}



	public int getCount() {
		return count;
	}



	public void setCount(int count) {
		this.count = count;
	}



	public Object getData() {
		return data;
	}



	public void setData(Object data) {
		this.data = data;
	}
   
}
